/** 
Copyright (c) 2010, Sheikh Abdul Wahid Ahmed
Details @ http://extremecodeworld.codeplex.com/license
**/

using System;
using System.Data;
using System.Configuration;
using System.Web;
using System.Web.Security;
using System.Web.UI;
using System.Web.UI.WebControls;
using System.Web.UI.WebControls.WebParts;
using System.Web.UI.HtmlControls;
using EXtremecode.Common.UI;
using EXtremecode.Common;


namespace EXtremecode.PresentationLayer
{

    /// <summary>
    /// Summary description for Frame
    /// </summary>
    public class Frame : Table
    {
        string title = string.Empty;
        string imageURL = string.Empty; 
        protected override void OnInit(EventArgs e)
        {
            base.OnInit(e);
            
            //get userProfile
            IUserProfile profile = SessionRepository.Instance.UserProfile;
            if (profile != null)
            {
                profile.Decorator.DecorateFrame(this, title,imageURL);
            }
            else
            {
                //default
                new XcodeDecorator().DecorateFrame(this, title,imageURL);

            }
            
        }

        public string Title
        {
            get
            {
                return title;
            }
            set
            {
                title = value;
            }
        }

        public string ImageURL
        {
            get
            {
                return imageURL;
            }
            set
            {
                imageURL = value;
            }
        }

    }
    public class FrameHeader : TableRow
    {
    }
    public class FrameFooter: TableRow
    {
    }
    public class FRow : TableRow
    {
    }
    public class FCell : TableCell
    {
    }
}